let suffix = "/cheetah";
let $ = layui.jquery;
$.ajaxSetup({
    layerIndex: -1,
    beforeSend: function () {
        this.layerIndex = layer.load(0, {shade: [0.2, '#bdc3c7']});
    },
    complete: function (res) {
        // 未登录刷新页面
        if (res.responseJSON && res.responseJSON.code == -2) {
            top.window.location.reload();
        }
        layer.close(this.layerIndex);
    },
    error: function (res) {
        console.log(res)
        layer.close(this.layerIndex);
    }
});

